<template>
  <el-dialog :title="title" :visible.sync="visible" :width="'500px'" class="w-addtree-dialog">
    <el-row>
      <el-col :span="5">
        <span class="name">名称：</span>
      </el-col>
      <el-col :span="15">
        <el-input v-model="inputVm" maxlength="50" show-word-limit></el-input>
      </el-col>
    </el-row>
    <span slot="footer" class="dialog-footer">
      <el-button size="small" @click="visible=false">取消</el-button>
      <el-button size="small" @click="onSubmitFrom()" type="primary" :loading="btnLoading">确定</el-button>
    </span>
  </el-dialog>
</template>
<script>
export default {
  data() {
    return {
      visible: false,
      inputVm: "",
      title: "",
      editType: "",
      btnLoading: false,
      subOrder: 1,
      openDate: {},
    };
  },
  methods: {
    onSubmitFrom() {
      if (!this.inputVm) {
        return this.$message.warning("名称必填");
      }
    },
  },
};
</script>